/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  v2006                                 |
|   \\  /    A nd           | Website:  www.openfoam.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    location    "system";
    object      controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


libs            (overset fvMotionSolvers);

application     overPimpleDyMFoam;

//startFrom       startTime;
startFrom       latestTime;

startTime       0;

stopAt          endTime;

endTime         20;

deltaT          0.0002;

writeControl    runTime;
//writeControl    timeStep;

writeInterval   0.025;

purgeWrite      60;

writeFormat     ascii;

writePrecision  6;

writeCompression off;

timeFormat      general;

timePrecision   6;

runTimeModifiable true;

// ************************************************************************* //
functions
{
    fieldAverage
    {
        type            fieldAverage;
        functionObjectLibs ("libfieldFunctionObjects.so");
        enabled         true;
        writeControl   outputTime;

	//writeControl   timeStep;
	//writeInterval  100;

	//cleanRestart true;

	timeStart       4;
	//timeEnd         200;

        fields
        (
            p
            {
                mean        on;
                prime2Mean  on;
                base        time;
            }
            U
            {
                mean        on;
                prime2Mean  on;
                base        time;
            }
        );
    }
    forceCoeffs
    {
         type forceCoeffs;
         functionObjectLibs ("libforces.so"); 
         patches (walls); 
         log true; 
         rho rhoInf;
         rhoInf 1;
         CofR (0 0 0);
         liftDir (0 1 0); 
         dragDir (1 0 0); 
         pitchAxis (0 0 1);
         magUInf 10; 
         lRef 0.1;
         Aref 0.1; 
         writeControl    timeStep;
         writeInterval   1;
    }
	vorticity
    {
        type        vorticity;
        libs        ("libfieldFunctionObjects.so");
        U		U;
        enabled         true;
        writeControl   outputTime;
	    writeInterval	1;
	    timeStart       0.002;
    }
    /*probes
	{
  		type probes; // Type of functionObject
		functionObjectLibs ("libsampling.so");
		probeLocations // Locations to be probed. runTime modifiable!
		(
			(1.0 0 0)
            (1.5 0 0)
            (2.0 0 0)
            (2.5 0 0)
            (3.0 0 0)
            (3.5 0 0)
            (4.0 0 0)
            (4.5 0 0)
            (5.0 0 0)
            (5.5 0 0)
            (6.0 0 0)
			(6.5 0 0)
		);
		// Fields to be probed. runTime modifiable!
		fields
		(
			U
		);
	}*/
}